@extends('admin.layout.base')

@section('content')
{{--
    <div class="layui-form-item">
        <div class="layui-inline">
            <input class="layui-input search-data" name="name" placeholder="账户名" autocomplete="off">
        </div>

        <div class="layui-inline layui-form">
            <select name="status" class="search-data">
                <option value="">状态</option>
                <option value="0">启用</option>
                <option value="1">停用</option>
            </select>
        </div>

        <div class="layui-inline demoTable">
            <button class="layui-btn layui-btn-sm layuiadmin-btn-useradmin" data-type="search" lay-filter="search">
                <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
            </button>
        </div>
    </div>--}}

    <div class="layui-card">
        <table class="layui-hide" id="tableData" lay-filter="myTable"></table>
    </div>

@endsection

@section('script')
    <script>
        layui.use(['table', 'layer', 'jquery'], function () {
            $ = layui.jquery;
            var table = layui.table;
            table.render({
                elem: '#tableData'
                , url: '{{route("actionLog.list")}}'
                , cols: [[
                    {field: 'id', title: 'ID', sort: true, width: 60}
                    , {field: 'admin_name', title: '操作人员', width: 120}
                    , {field: 'route', title: '请求路由', width: 180}
                    , {field: 'method', title: '请求类型', width: 90}
                    , {field: 'table_id', title: '数据id', width: 80}
                    , {field: 'actinname', title: '路径'}
                    , {field: 'ip', title: 'IP地址', width: 150}
                    , {field: 'created_at', title: '操作时间', width: 160}
                ]]
                , id: 'myReload'
                , page: true
            });
        });
    </script>
@endsection